<template>
	<view>
		<view class="details_box">
			<text class="tit">{{data.title}}</text>
			<u--text :text="data.create_time_text" color="#e1e1e1" class="tit_time"></u--text>
			<text class="cont" v-html="data.content"></text>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				id: null,
				data:{}
			}
		},
		onLoad(e) {
			this.id = e.id
			this._list()
		},
		methods: {
			//列表接口
			async _list() {
				uni.showLoading({
					title: '加载中'
				});
				const userinfo = uni.getStorageSync('userinfo');
				const {
					data: res
				} = await this.$myHttp5({
					url: 'Information/details',
					data: {
						id: this.id
					},
					header: {
						'token': userinfo.token
					},
				});
				this.data = res.data
				uni.hideLoading();
			},
		}
	}
</script>

<style lang="scss" scoped>
	.details_box {
		padding: 50rpx;
		box-sizing: border-box;
	
		.tit {
			font-size: 36rpx;
			padding-bottom: 15rpx;
			display: block;
			text-align: center;
		}
		
		.tit_time {
			// flex: 1;
			display: flex;
			justify-content: flex-end !important;
			text-align: right;
			font-size: 24rpx;
		}

		.cont {
			font-size: 28rpx;
			color: #333333;
			display: block;
			margin-top: 10rpx;
			border-top: #eee 1px dashed;
			padding-top: 20rpx;
		}
	}
</style>
